<?php

namespace core\lib;

class logs
{
	static public $class;
	/*
		1.确定存储方式
		
		2.写日志

	*/
	
	static public function init()
	{
		/*
			确定日志存储方式
		*/
		$driver = config::get('DRIVER', 'logs');
		$class =  '\\core\\lib\\driver\\logs\\'.$driver;
		self::$class = new $class();
	}
	
	static public function write($message, $file = 'Tisa')
	{
		self::$class->write($message, $file);
	}
}